<template>
  <el-menu
      router
      default-active="/ca/home"
      class="el-menu-vertical-demo"
      @open="handleOpen"
      @close="handleClose">
    <el-menu-item index="/ca/home">
      <el-icon>
        <icon-menu/>
      </el-icon>
      <span>首页</span>
    </el-menu-item>
    <el-menu-item index="/ca/test">
      <el-icon>
        <setting/>
      </el-icon>
      <span>测试</span>
    </el-menu-item>
  </el-menu>
</template>


<script setup lang="ts">
import {
  Menu as IconMenu,
  Setting,
} from '@element-plus/icons-vue'
const handleOpen = (key: string, keyPath: string[]) => {
  console.log(key, keyPath)
}
const handleClose = (key: string, keyPath: string[]) => {
  console.log(key, keyPath)
}
</script>


<style scoped lang="scss">

</style>